package com.lyx.server.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import java.util.Date;

import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.Data;
import lombok.NoArgsConstructor;

/**
 * 短信发送表
 * @TableName t_sms_log
 */
@TableName(value ="t_sms_log")
@Data
@NoArgsConstructor
public class SmsLog extends  Model<SmsLog> {
    /**
     * 序号，主键
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * ⼿机号
     */
    @TableField(value = "phone")
    private String phone;

    /**
     * 类型
     */
    @TableField(value = "type")
    private String type;

    /**
     * 内容
     */
    @TableField(value = "info")
    private String info;

    /**
     * 创建时间
     */
    @TableField(value = "create_time")
    private Date createTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    public SmsLog(String phone, String type, String info) {
        this.phone = phone;
        this.type = type;
        this.info = info;
        this.createTime=new Date();
    }
}
